#HEALTH OF ONLINE COMMUNITIES
#Clean Names
#
#Remove IP addresses from data and replace underscores with spaces

import re
import sys


def main():
			
	for line in sys.stdin:
		pieces = line.split('\t')
		if not re.search(r'\b25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?\.25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?\.25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?\.25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?\b',user):
			print '\t'.join([user, pieces[1], pieces[2], pieces[3]]) #outputs only data from non-ip addresses



#used to remove data pre-2003
def eraseEarlyYears():

	for line in sys.stdin:
		pieces = line.split('\t')		
		user = pieces[0].replace('_',' ') #replaces underscores with spaces
		datetime = pieces[1]
		time = datetime.split('T')
		date = time[0]
		dates = date.split('-')
		year = dates[0]
		if not int(year) < 2003:
			print line.replace("\n", "")

eraseEarlyYears()
